<template>
	<view class="root-wrap">
		<image class="logo" src="../../../static/assets/imgs/logo.png" mode=""></image>
		<view class="welcome-text">欢迎注册海信探索中心报修比价系统</view>
		<view class="check"><u-checkbox v-model="agree" activeColor="#30D6C2" @change="checkChange"></u-checkbox><text class="tips">请同意<text @click="goAgreement('confident')">“保密协议”</text>和<text @click="goAgreement('privacy')">“隐私协议”</text></text></view>
		<view class="submit" @click="goSignIn"><u-button color="#30D6C2" type="primary" shape="circle">我要注册<image class="icon" src="../../../static/assets/imgs/next-step.png"></image></u-button></view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				agree: false
			};
		},
		methods:{
			checkChange(e){
				this.agree = e;
			},
			goSignIn(){
				if(!this.agree){
					uni.showToast({
						title:'请阅读并同意勾选协议',
						icon:'none'
					})
				}else{
					uni.navigateTo({
						url:'/pages/my/sign/sign'
					})
				}
				
			},
			goAgreement(type){
				uni.navigateTo({
					url: '/pages/my/sign/agreement?type='+type
				})
			}
		}
	}
</script>

<style lang="scss">
	.root-wrap{
		display: flex;
		flex-direction: column;
		justify-content: flex-start;
		align-items: center;
		.logo{
			width: 556rpx;
			height: 192rpx;
			margin-top: 238rpx;
		}
		.welcome-text{
			width: 432rpx;
			font-weight: 500;
			font-size: 36rpx;
			color: #000000;
			line-height: 56rpx;
			text-align: center;
			margin-top: 28rpx;
		}
		.check{
			display: flex;
			justify-content: center;
			align-items: center;
			margin-top: 136rpx;
			.tips{
				font-size: 28rpx;
				color: #909399;
				margin-left: 32rpx;
			}
		}
		.submit{
			width: 272rpx;
			height: 80rpx;
			margin-top: 356rpx;
			.icon{
				width: 48rpx;
				height: 48rpx;
				margin-left: 16rpx;
			}
		}
	}
</style>
